
package com.drumbeatinsight.html {
	import com.drumbeatinsight.controls.HTML;
	
	import mx.core.Application;

	public class HTMLElement {
		
		public function HTMLElement():void {
			
		}
		
		// static
		public var position:String = "absolute";
		// why am i not using frameBorder??? should be changed in js if changed here
		// addendum: possible reasons could be to prevent case sensitivity issues in the browser
		public var frameborder:int = 0;
		
		// we set as string so we can pass percentages
		public var width:String = "0";
		public var height:String = "0";
		
		public var x:int = 0;
		public var y:int = 0;
		public var source:String = "about:blank";
		public var htmlText:String = "";
		public var type:String = "";
		public var name:String = "";
		public var id:String = "";
		public var color:String = "";
		public var backgroundColor:String = "transparent";
		public var backgroundTransparent:Boolean = false;
		public var border:String = "0px";
		public var htmlScrollPolicy:String = "auto";
		public var fontSize:Number = 10;
		public var movieId:String = Application.application.id;
		public var editorPath:String = "fckeditor/";
		public var configPath:String = "";
		public var includesBefore:Array = [];
		public var includesAfter:Array = [];
		public var javascript:String = "";
		public var editorType:String = "fckeditor";
		public var editorOptions:* = "";
		public var visible:Boolean = true;
		public var fitToContentHeight:Boolean = false;
		public var padding:String = "0px";
		
		// for mocha pop up
		public var loadMethod:String = "html";
		public var chrome:Boolean = false;
		public var title:String = "";
		public var modal:Boolean = false;
		public var minimizable:Boolean = false;
		public var maximizable:Boolean = false;
		public var closable:Boolean = false; // we don't want to show close button on an alert window
		public var resizable:Boolean = true;
		public var draggable:Boolean = true;
		public var centerPopUp:Boolean = false;
		public var alert:Boolean = false;
		public var alertButtons:Array = [];
		public var headerHeight:Number = 32;
		public var headerTitleTop:Number = 10;
		public var headerControlsTop:Number = 10;
		public var footerHeight:Number = 16;
		public var popUpOptions:* = "";
		
		// used to return a full 6 character color 
		// for example, "#00ff00" returns "ff00" when using Number(getStyle('color')).toString(16);
		// this method would return "00fff00"
		public function padColor(o:HTML, value:String):String {
			var color:String = Number(o.getStyle(value)).toString(16);
			var len:int = (color!=null && color!="") ? color.length : 0;
			for (var i:int = len; i<6; i++) {
				color = "0" + String(color);
			}
			return color;
		}
	}
		
	
}